function login(){
	var userName = $("#username").val();
	var pwd = $("#password").val();
	if(!pwd || !userName){
		layer.alert("用户名密码不能为空");
		return ;
	}
	
	$.ajax({
	    type: "POST",
        url: "/ac/grp/login",
        contentType: "application/json; charset=utf-8",
        data: JSON.stringify({"userName":userName,"pwd":pwd}),
        success: function (data) {
        	debugger;
        	if(data.errno==200){
        		window.location.href="menu.html";
        	}else{
        		layer.alert("用户名或密码错误");
        	}
        },
        error: function () {
        	layer.alert("用户名或密码错误");
        }
    });
	
}